<?php



class StageMapBuilder {

	
	const CLASS_NAME = 'lib.model.map.StageMapBuilder';

	
	private $dbMap;

	
	public function isBuilt()
	{
		return ($this->dbMap !== null);
	}

	
	public function getDatabaseMap()
	{
		return $this->dbMap;
	}

	
	public function doBuild()
	{
		$this->dbMap = Propel::getDatabaseMap('propel');

		$tMap = $this->dbMap->addTable('stage');
		$tMap->setPhpName('Stage');

		$tMap->setUseIdGenerator(true);

		$tMap->addPrimaryKey('ID', 'Id', 'int', CreoleTypes::INTEGER, true, null);

		$tMap->addForeignKey('ETUDIANT_ID', 'EtudiantId', 'int', CreoleTypes::INTEGER, 'etudiant', 'ID', true, null);

		$tMap->addForeignKey('SOCIETE_ID', 'SocieteId', 'int', CreoleTypes::INTEGER, 'societe', 'ID', true, null);

		$tMap->addColumn('POSTE', 'Poste', 'string', CreoleTypes::VARCHAR, true, 255);

		$tMap->addColumn('TAG', 'Tag', 'string', CreoleTypes::VARCHAR, false, 255);

		$tMap->addColumn('CREATED_AT', 'CreatedAt', 'int', CreoleTypes::TIMESTAMP, false, null);

		$tMap->addColumn('DEBUT', 'Debut', 'int', CreoleTypes::DATE, false, null);

		$tMap->addColumn('FIN', 'Fin', 'int', CreoleTypes::DATE, false, null);

		$tMap->addColumn('REMUNERATION', 'Remuneration', 'int', CreoleTypes::INTEGER, true, null);

		$tMap->addColumn('POURSUITE_STAGE', 'PoursuiteStage', 'string', CreoleTypes::VARCHAR, true, 45);

		$tMap->addColumn('ADRESSE', 'Adresse', 'string', CreoleTypes::VARCHAR, false, 255);

		$tMap->addColumn('CODE_POSTAL', 'CodePostal', 'string', CreoleTypes::VARCHAR, false, 5);

		$tMap->addColumn('VILLE', 'Ville', 'string', CreoleTypes::VARCHAR, false, 45);

		$tMap->addColumn('PAYS', 'Pays', 'string', CreoleTypes::VARCHAR, false, 5);

		$tMap->addColumn('GEOLOCALISATION', 'Geolocalisation', 'string', CreoleTypes::VARCHAR, false, 255);

		$tMap->addColumn('RECOMMANDER', 'Recommander', 'boolean', CreoleTypes::BOOLEAN, false, null);

		$tMap->addColumn('APPRECIATION', 'Appreciation', 'string', CreoleTypes::LONGVARCHAR, false, null);

		$tMap->addColumn('EMAIL_TUTEUR', 'EmailTuteur', 'string', CreoleTypes::VARCHAR, false, 45);

		$tMap->addColumn('NIVEAU_IMAC', 'NiveauImac', 'string', CreoleTypes::VARCHAR, true, 1);

	} 
} 